Skip to content

Conversation

@Thomas55555
Copy link
Contributor

@Thomas55555 Thomas55555 commented Dec 22, 2025

Proposed change

Add ppb as a valid uom for sensor/number NO2 device class

Type of change

  • Document existing features within Home Assistant
  • Document new or changing features for which there is an existing pull request elsewhere
  • Spelling or grammatical corrections, or rewording for improved clarity
  • Changes to the backend of this documentation
  • Remove stale or deprecated documentation

Checklist

  • I have read and followed the documentation guidelines.
  • I have verified that my changes render correctly in the documentation.

Additional information

Summary by CodeRabbit

  • Documentation
    • Updated nitrogen dioxide unit support to include both ppb and µg/m³ measurements
    • Expanded device class documentation with additional supported environmental measurement classes including nitrogen oxides, ozone, particulate matter, pressure, temperature, and wind-related measurements

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 22, 2025

📝 Walkthrough

Walkthrough

Documentation updates to the number and sensor entity device class specifications, expanding supported device classes and updating unit specifications for nitrogen dioxide measurements.

Changes

Cohort / File(s) Summary
Device class documentation updates
docs/core/entity/number.md, docs/core/entity/sensor.md
Updated NumberDeviceClass and SensorDeviceClass documentation tables. Modified NITROGEN_DIOXIDE unit support to include both ppb and µg/m³. Expanded number device class table with additional device classes (nitrogen compounds, ozone, pH, particulate matter, power metrics, precipitation, pressure, signal strength, sound pressure, speed, sulphur dioxide, temperature, volatile organic compounds, voltage, volume, water, weight, wind metrics, and others).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Pure documentation content changes with no code logic or functional modifications
  • Changes consist of markdown table updates and clarifications

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: adding ppb as a valid unit for NO2 device class in sensor/number entities.
Description check ✅ Passed The description follows the template structure with all required sections completed: proposed change, type of change selected, checklist items marked, and additional information with relevant PR link provided.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

📜 Recent review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Cache: Disabled due to data retention organization setting

Knowledge base: Disabled due to data retention organization setting

📥 Commits

Reviewing files that changed from the base of the PR and between 4c5ac2f and 9312067.

📒 Files selected for processing (2)
  • docs/core/entity/number.md
  • docs/core/entity/sensor.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Redirect rules - developers-home-assistant
  • GitHub Check: Header rules - developers-home-assistant
  • GitHub Check: Pages changed - developers-home-assistant
🔇 Additional comments (2)
docs/core/entity/sensor.md (1)

62-62: Documentation correctly reflects ppb as valid UoM for NITROGEN_DIOXIDE.

The change properly adds ppb to the supported units for the sensor's NITROGEN_DIOXIDE device class and follows the same table format as other gas concentration entries.

Please verify that the unit ordering (ppb listed first, µg/m³ second) matches the precedence or recommendation in the corresponding Core PR implementation (home-assistant/core#159426).

docs/core/entity/number.md (1)

59-59: Consistent documentation update across both sensor and number entity types.

The number entity's NITROGEN_DIOXIDE device class has been updated in alignment with the sensor entity change, maintaining documentation consistency across entity types.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@abmantis abmantis merged commit efc1ac3 into home-assistant:master Jan 20, 2026
5 checks passed
@Thomas55555 Thomas55555 deleted the no2 branch January 21, 2026 06:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants